package ee.maoinvest.backend.model.dao;

import java.sql.Date;
import java.util.List;

import ee.maoinvest.backend.model.data.Enterprise;

public interface EnterpriseDAO 
{
	//basic CRUD
	public int insertEnterprise(Enterprise enterprise);
	public Enterprise getEnterpriseByID(int enterpriseID);
	public List<Enterprise> getAllEnterprisesThatAreNotWrittenOff();
	public int updateEnterprise(Enterprise updatedEnterprise);
	public int deleteEnterprise(int enterpriseID);
	
	public Date getDateDefaultEnterpriseWasInsertedIntoSystem();
	
	public Enterprise getDefaultEnterprise();
	public int setIsEnterpriseActive(int enterpriseID, boolean isActive);
	public List<Enterprise> getAllEnterprisesThatExistedBetweenDatesGivenRegularReadingsTookPlace(
			Date minDateRegularReadingWasTaken, Date maxDateRegularReadingWasTaken);
	public List<Enterprise> getListOfEnterprisesThatWereInRelationWithSubstationMainElectrcityMetersBetweenDatesGivenRegularReadingsTookPlace(
			Date minDateRegularReadingWasTaken, Date maxDateRegularReadingWasTaken);
	public List<Enterprise> findEnterprisesByBusinessName(String businessName, int maxRows);
}
